package com.swf.common.utils;

import com.swf.common.base.*;

/**
 * description:编码获取类
 * @version 1.0 2013-5-12
 * @author shenwf
 */
public final class LanguageUtils {
	/**
	 * 禁用默认构造器	
	 */
	private LanguageUtils() {
	}
	/**
	 * 获取默认编码
	 * @return
	 */
	public static String getEncoding(){
		return FwsStandard.encoding;
	}
	
	public static String getEncoding(String encoding){
		if (encoding!=null && encoding.length()!=0){
			return encoding;
		}
		return FwsStandard.encoding;
	}
	
	public static String getEncodingByType(String type){
		if (type!=null && type.length()!=0){
			String encoding =FwsStandard.getEncodingByType(type);
			return getEncoding(encoding);
		}
		return FwsStandard.encoding;
	}
}
